<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>


<body>

<div id="vue">
    <div>{{info.name}}</div>
    <a v-bind:href="info.url">点我</a>
</div>


<script src="https://cdn.jsdelivr.net/npm/vue@2.5.21/dist/vue.js"></script>
<script src="https://unpkg.com/axios/dist/axios.min.js"></script>
<script type="text/javascript"></script>
<!--导入vue。js-->
<script>
    var vm = new Vue({
        el:"#vue",
        data(){
            return{
                //请求的返回参数合适，必须和json字符串一样
                info:{

                }
            }
        },
        monthed(){//钩子函数
            axios.get('../data.json').then(response=>(this.info=response.data));
        }
    });


</script>



</body>
</html>